package com.wang.security.custom;

import com.wang.common.config.exception.CustomException;
import org.springframework.security.core.userdetails.UserDetails;
import org.springframework.security.core.userdetails.UserDetailsService;
import org.springframework.security.core.userdetails.UsernameNotFoundException;

/**
 * @author wjh
 * @create 2023-05-27
 */
public interface UserDetailService extends org.springframework.security.core.userdetails.UserDetailsService {

    /**
     * 根据用户名获取用户对象（获取不到直接抛出异常）
     */
    UserDetails loadUserByUsername(String userName) throws UsernameNotFoundException;
}
